/*
 * @Author: 高瑞寒 15932717091@163.com
 * @Date: 2021-12-13 10:45:26
 * @LastEditTime: 2022-03-22 21:33:24
 * @LastEditors: 高瑞寒 15932717091@163.com
 * @Description: 
 */
const Koa = require('koa')
//创建实例对象
const app = new Koa()
//响应时长中间件
const resDurationMiddleware = require('./middleware/koa_response_duration')
//设置请求头中间件
const resHeaderMiddleware = require('./middleware/koa_response_header')
//业务逻辑中间件
const resDataMiddleware = require('./middleware/koa_response_data')
app.use(resDurationMiddleware)
app.use(resHeaderMiddleware)
app.use(resDataMiddleware)
app.listen('3001', () => {
  console.log('服务已启动,localhost:3000');
})
const Websocket = require('./server/websocket_series')
Websocket.wsUtil()